<template>
    <div>

      <el-table v-loading="loading" :data="infoList">
        <el-table-column type="selection" width="55" align="center" />
        <el-table-column label="供应商ID" align="center" prop="supplierId" />
        <el-table-column label="供应商编码" align="center" prop="supplierCode" :show-overflow-tooltip="true" />
        <el-table-column label="供应商名称" align="center" prop="supplierName" :show-overflow-tooltip="true" />
        <el-table-column label="店铺类型" align="center" prop="supplierTypeform" >
          <template slot-scope="scope">
            <span>{{ scope.row.supplierTypeform == 1 ? "物品":"技术" }}</span>
          </template>
        </el-table-column>
        <el-table-column label="供应商联系人" align="center" prop="linkMan" :show-overflow-tooltip="true" />
        <el-table-column label="联系电话" align="center" prop="phoneNumber" :show-overflow-tooltip="true" />
        <el-table-column label="供应商地址" align="center" prop="address" :show-overflow-tooltip="true" />
        <el-table-column label="店铺名称" align="center" prop="shopsName" :show-overflow-tooltip="true" />
        <el-table-column label="资质证书简介" align="center" prop="certificateText" :show-overflow-tooltip="true" />
        <el-table-column label="业务简介" align="center" prop="supplierTypeText" :show-overflow-tooltip="true" />

      </el-table>

      <pagination
        v-show="total>0"
        :total="total"
        :page.sync="queryParams.pageNum"
        :limit.sync="queryParams.pageSize"
        @pagination="getList"
      />


    </div>
</template>

<script>
  import { findAll } from "@/api/system/substations";

  export default {
        name: "zhanshi",
      data(){
          return{
            // 遮罩层
            loading: true,
            // 供应商信息表格数据
            infoList: [],
            // 查询参数
            queryParams: {
              pageNum: 1,
              pageSize: 10,
              supplierCode: null,
              supplierName: null,
              supplierType: null,
              supplierTypeform: null,
              linkMan: null,
              phoneNumber: null,
              bankName: null,
              bankAccount: null,
              address: null,
              supplierStatus: null,
              modifiedTime: null,
              shopsName: null,
              customerId: null,
              platformId: null,
              licenseUrl: null,
              supplierPic: null,
              certificate: null,
              certificateText: null,
              supplierTypeText: null
            },
          }
      },
      created() {
        this.getList();
      },
      methods: {
        getList() {
          this.loading = true;
          findAll(this.queryParams).then(response => {
            this.infoList = response.rows;
            this.total = response.total;
            this.loading = false;
          });
        },
      }
    }
</script>

<style scoped>

</style>
